<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        var deep = {
            deep: 'deep'
        }


        let obj = {
            name: 'zs',
            is: () => {

            }
        }
        let flag = Object.is('zs', 'zs')

        // assign() 合并对象 浅拷贝

        let obj1 = {
            name: 'zs'
        }

        let obj2 = {
            age: '19'
        }


        var obj3 = Object.assign(obj1, obj2);
        console.log(obj1);
        console.log(obj2);
        console.log(obj3);
        obj1.deep = deep


        var obj4 = {
            ...obj1,
            ...obj2
        }
        console.log(obj4)
    </script>
</body>

</html>